colorAdminApp.controller('interviewStartController', function($scope,$cookieStore,$compile,$rootScope,$http,$state,$stateParams,modalService) {
	
	$scope.entity={"interviewerName":"","jobTitle":""};
	
	
	$scope.start=function(entity){
		
		if(entity.interviewerName==""){
			alert("应骋人员姓名不能为空！");return;
		}
		if(entity.jobTitle==""){
			alert("应骋人职位不能为空！");return;
		}
		
		entity["processDefinitionId"]=$stateParams.processDefinitionId;
    	
    	$http.post('api/workflow/process/instance/start',{params:entity}).success(function(data, status, headers, config) {
			
    		$("body").unblock();
    		
    		modalService.showAlertModal('注意',data.message);
			
			
		}).error(function(data, status, headers, config) {
			$("body").unblock();
       });  
    	
	};
	
	
		
    
	
});
